﻿// ***********************************************************************
// Apache 2.0 License
// Licensed under the Apache License, Version 2.0 (the "License"); you may
// not use this file except in compliance with the License. You may obtain
// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 
//
// THIS CODE IS PROVIDED *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
// ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY 
// IMPLIED WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR 
// PURPOSE, MERCHANTABLITY OR NON-INFRINGEMENT.
//
// See the Apache Version 2.0 License for specific language governing
// permissions and limitations under the License.
// ***********************************************************************
// Assembly  : ContractMeow.Api.Dtos
// File      : Network.cs
//
// ***********************************************************************
using Newtonsoft.Json;
using System;
using System.Collections.Generic;

namespace ContractMeow.Api.Dtos
{
	// "network":{
	//   "type":"network",
	//   "profile_fields_config":{
	//      "enable_work_phone":true,
	//      "enable_job_title":true,
	//      "enable_mobile_phone":true
	//   },
	//},

	public sealed class GroupCounts
	{
		[JsonProperty("unseen_general_thread_count")]
		public int UnseenGeneralThreadCount { get; set; }
		[JsonProperty("unseen_group_thread_counts")]
		public Dictionary<long, int> UnseenGroupThreadCounts { get; set; }
	}

	public sealed class Network
	{
		[JsonProperty("id")]
		public Int64 Id { get; set; }
		[JsonProperty("name")]
		public String Name { get; set; }
		[JsonProperty("permalink")]
		public String Permalink { get; set; }
		[JsonProperty("web_url")]
		public Uri WebUrl { get; set; }
		[JsonProperty("created_at")]
		public DateTimeOffset? CreatedAt { get; set; }

		[JsonProperty("paid")]
		public Boolean IsPaid { get; set; }
		[JsonProperty("is_chat_enabled")]
		public Boolean IsChatEnabled { get; set; }
		[JsonProperty("is_group_enabled")]
		public Boolean IsGroupEnabled { get; set; }
		[JsonProperty("is_org_chart_enabled")]
		public Boolean IsOrgChartEnabled { get; set; }
		[JsonProperty("community")]
		public Boolean IsCommunity { get; set; }
		[JsonProperty("show_upgrade_banner")]
		public Boolean ShowUpgradeBanner { get; set; }

		[JsonProperty("inbox_unseen_thread_count")]
		public Int32? InboxUnseenThreadCount { get; set; }
		[JsonProperty("private_unseen_thread_count")]
		public Int32? PrivateUnseenThreadCount { get; set; }
		[JsonProperty("unseen_notification_count")]
		public Int32? UnseenNotificationCount { get; set; }

		[JsonProperty("group_counts")]
		public GroupCounts GroupCounts { get; set; }

		#region Display properties
		[JsonProperty("header_text_color")]
		public String HeaderTextColor { get; set; }
		[JsonProperty("header_background_color")]
		public String HeaderBackgroundColor { get; set; }
		[JsonProperty("navigation_text_color")]
		public String NavigationTextColor { get; set; }
		[JsonProperty("navigation_background_color")]
		public String NavigationBackgroundColor { get; set; }
		#endregion
	}
}